﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services;
using AdaptiveHelpDesk.AUI_Model_Components.Analysis_Engine;
using AdaptiveHelpDesk;


namespace Novice.Services
{
    /// <summary>
    /// Summary description for Expertise
    /// </summary>
    [WebService(Namespace = "http://soaiui.nmmu.ac.za/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    [System.ComponentModel.ToolboxItem(false)]
    // To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line. 
    // [System.Web.Script.Services.ScriptService]
    public class Expertise : System.Web.Services.WebService
    {
        AnalyzeSkillLevel analyse = new AnalyzeSkillLevel();
        GetTaskModel gt = new GetTaskModel();

        [WebMethod]
        public bool isExpert(string userid)
        {
            bool expertise = analyse.isExpert(userid);
            if (expertise == true)
            {
                gt.SetStereoptype("Expert");
                return true;
            }
            else
            {
                gt.SetStereoptype("Novice");
                return false;
            }
        }
    }
}
